# from web_backend.sacem.services.TrainFirmwareService import get_firmware_version
from datetime import date
import datetime
import csv
from django.apps import apps
from backend.cews.models import StockItem


class Echo(object):
    def write(self, value):
        return value
    
def getCSVWriter():
    CSVWriter = csv.writer(Echo())
    return CSVWriter

def queryStockItemList():
    MyModel = apps.get_model('cews', 'StockItem')
    headers = [field.verbose_name.title() for field in MyModel._meta.get_fields()]
    print("headers", headers)
    return 

